<%@ page contentType="text/html; charset=utf-8" pageEncoding="utf-8" %>
<%@ taglib prefix="s" uri="http://stripes.sourceforge.net/stripes.tld" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="f" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags" %>

<s:layout-definition>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
        <head>
            <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
            <title><s:layout-component name="hlavicka"/></title>
            <meta name="keywords" content="extreme, services, css templates, website templates, web design" />
            <meta name="description" content="Extreme is a free website template that can be used for any purpose" />
            <link href="${pageContext.request.contextPath}/css/templatemo_style.css" rel="stylesheet" type="text/css" />
            <link href="css/jquery.ennui.contentslider.css" rel="stylesheet" type="text/css" media="screen,projection" />
        </head>
        <body>
            <div id="templatemo_header_wrapper">
                <div id="templatemo_header">

                    <div id="site_title">
                        <shiro:hasRole name="admin">
                            <h1>
                                <s:link href="/all"> <f:message key="key.admin"/></s:link>
                                </h1>
                        </shiro:hasRole>
                        <shiro:lacksRole  name="admin">
                            <h1>
                                <s:link href="/all"> <f:message key="key.home"/></s:link>
                                </h1>
                        </shiro:lacksRole>
                    </div>

                    <div id="templatemo_menu">
                        <ul>
                            <li><s:link href="/all"> <f:message key="key.home"/></s:link></li>
                            <shiro:hasRole name="admin">
                                <li><s:link href="/customers/all"> <f:message key="key.customers"/></s:link></li>
                                <li><s:link href="/services/all"><f:message key="key.services"/></s:link></li>
                                <li><s:link href="/tyres/all"><f:message key="key.tyres"/></s:link></li>
                                <li><s:link href="/orders/all"><f:message key="key.orders"/></s:link></li>
                            </shiro:hasRole>
                            <shiro:notAuthenticated>
                                <li><s:link href="/auth"><f:message key="key.login"/></s:link></li>
                            </shiro:notAuthenticated>
                            <shiro:hasRole name="Customer">
                                <li><s:link href="/customerLogged.jsp"><f:message key="key.myAccount"/></s:link></li>
                            </shiro:hasRole>
                            <shiro:authenticated>
                                <li><s:link href="/logout.jsp"><f:message key="key.logout"/></s:link></li>
                            </shiro:authenticated>
                        </ul>    	
                    </div> <!-- end of templatemo_menu -->

                    <div class="cleaner"></div>
                </div> <!-- end of header -->
            </div> <!-- end of header_wrapper -->

            <div id="templatemo_content_wrapper">
                <div id="templatemo_content">

                    <div class="cleaner_h30"></div>

                    <s:layout-component name="telo"/>

                </div> <!-- end of content -->
            </div> <!-- end of content_wrapper -->

            <div id="templatemo_copyright_wrapper">
                <div id="templatemo_copyright">

                    Copyright © 2012 <a href="#">Your Company Name</a> | 
                    Designed by <a href="http://www.templatemo.com" target="_parent">Free CSS Templates</a> | 
                    Validate <a href="http://validator.w3.org/check?uri=referer">XHTML</a> &amp; <a href="http://jigsaw.w3.org/css-validator/check/referer">CSS</a>

                </div> <!-- end of templatemo_copyright -->
            </div> <!-- end of copyright wrapper -->
        </body>
    </html>
</s:layout-definition>